package com.qu.tabhost.tabs.widget;

import com.qu.tabhost.R;
import com.qu.tabhost.fragment.ChatFragment;
import com.qu.tabhost.fragment.NewsFragment;
import com.qu.tabhost.fragment.PictureFragment;
import com.qu.tabhost.fragment.VideoFragment;

/**
 * Created by quguangle on 2017/5/18.
 * 采用枚举来初始化底部的tab
 */

public enum  MainTab {
    CHAT(0, R.string.nav_my,R.drawable.tab_icon_chat, ChatFragment.class),
    NEWS(1, R.string.nav_news,R.drawable.tab_icon_me, NewsFragment.class),
    QUICK(2, R.string.main_tab_name_quick, R.mipmap.floatactionbar,
            null),
    PICTURE(3, R.string.nav_discover,R.drawable.tab_icon_picture, PictureFragment.class),
    VIDEO(4, R.string.nav_video,R.drawable.tab_icon_video, VideoFragment.class);
    private int idx;
    private int title;
    private int icon;
    private Class<?> clx;
    MainTab(int idx,int title,int icon,Class<?> clx){
        this.idx = idx;
        this.title = title;
        this.icon = icon;
        this.clx = clx;
    }
    public int getIdx() {
        return idx;
    }

    public void setIdx(int idx) {
        this.idx = idx;
    }

    public int getTitle() {
        return title;
    }

    public void setTitle(int title) {
        this.title = title;
    }

    public int getIcon() {
        return icon;
    }

    public void setIcon(int icon) {
        this.icon = icon;
    }

    public Class<?> getClx() {
        return clx;
    }

    public void setClx(Class<?> clx) {
        this.clx = clx;
    }
}